<table id="userother_tt"></table>
<script language="javascript">
var data = {                                                      
	"total":239,                                                      
	"rows":[                                                          
		{"code":"001","name":"Name 1","addr":"Address 11","col4":"col4 data"},         
		{"code":"002","name":"Name 2","addr":"Address 13","col4":"col4 data"},         
		{"code":"003","name":"Name 3","addr":"Address 87","col4":"col4 data"},         
		{"code":"004","name":"Name 4","addr":"Address 63","col4":"col4 data"},         
		{"code":"005","name":"Name 5","addr":"Address 45","col4":"col4 data"},         
		{"code":"006","name":"Name 6","addr":"Address 16","col4":"col4 data"},          
		{"code":"007","name":"Name 7","addr":"Address 27","col4":"col4 data"},          
		{"code":"008","name":"Name 8","addr":"Address 81","col4":"col4 data"},          
		{"code":"009","name":"Name 9","addr":"Address 69","col4":"col4 data"},          
		{"code":"010","name":"Name 10","addr":"Address 78","col4":"col4 data"},    
		{"code":"011","name":"Name 10","addr":"Address 78","col4":"col4 data"},     
		{"code":"012","name":"Name 10","addr":"Address 78","col4":"col4 data"},     
		{"code":"013","name":"Name 10","addr":"Address 78","col4":"col4 data"}  
	]                                                          
};

$('#userother_tt').datagrid({
	title: '这里是测试数据'
	, fit: true
	, singleSelect: true
	, rownumbers: true /*行号*/
	, loadMsg: '正在加载数据，请稍等 ...'
	, columns:[[
		{field:'code',title:'Code',width:100}
		, {field:'name',title:'Name',width:100}
		, {field:'price',title:'Price',width:100,align:'right'}   
	]]  
	, toolbar:[{
			id:'userother_ref'
			, text: '刷新'
			, handler:function(){
				$('#userother_tt').datagrid("options").url = 'test.json';
				$('#userother_tt').datagrid("load", {});
			}
		}] 
});
$('#userother_tt').datagrid('loadData', data);
</script>
